<?php
use ServiceComponents\Enum\HostEnum;
return [
    'name'  => 'Swoft framework 2.0',
    'swoft_debug' => HostEnum::SWOFT_DEBUG,
    'app_debug' => HostEnum::APP_DEBUG,
    'consul' => [
        "SERVICE_ID"=>HostEnum::ConsulServiceIdGateway,
        "SERVICE_NAME"=>HostEnum::ConsulServiceNameGateway,
        "HOST"=>HostEnum::ConsulHost,
        "PORT"=>HostEnum::ConsulPort,
        "TIMEOUT"=>HostEnum::ConsulTimeout
    ],
    'application' => [
        "HTTP_PORT"=>HostEnum::ServiceGatewayHttpPort,
        "TCP_PORT"=>HostEnum::ServiceGatewayTcpPort,
        "WS_PORT"=>HostEnum::ServiceGatewayWsPort
    ],
    'redis' => [
        "HOST"=>HostEnum::RedisHost,
        "PORT"=>HostEnum::RedisPort,
        "PASSWORD"=>HostEnum::RedisPassword
    ],
    'Es' => [
        HostEnum::ElasticsearchHost.':'.HostEnum::ElasticsearchPort
    ],
    'Apollo' => [
        "HOST"=>HostEnum::ApolloHost,
        "PORT"=>HostEnum::ApolloPort,
        "APPID"=>HostEnum::ApolloAppid,
        "TIMEOUT"=>HostEnum::ApolloTimeout,
    ],
    #fastdfs
    'fastdfs'=>[
        'host'  => HostEnum::FastdfsHost,
        'port'  => HostEnum::FastdfsPort,
        'group' => [
            'group1'
        ],
    ],
    # 连接信息
    'AMQP' => [
        'host' => HostEnum::RabbitmqHost,
        'port'=> HostEnum::RabbitmqPortService,
        'login'=>HostEnum::RabbitmqLogin,
        'password'=> HostEnum::RabbitmqPassword,
        'vhost'=> HostEnum::RabbitmqVhost
    ],
    # 商品队列
    'goods_queue' => [
        'exchange_name' => 'topic_exchange',    //对应topic队列交换机名称
        'exchange_type'=>'topic',           //主题
        'queue_name' => 'goods_queue',
        'route_key' => "*.goods",      //模糊匹配
        'consumer_tag' => 'goods'
    ],
    # 订单队列
    'order_queue' => [
        'exchange_name' => 'topic_exchange',//对应topic队列交换机名称
        'exchange_type'=>'topic',//主题
        'queue_name' => 'order_queue',
        'route_key' => '*.order',    //模糊匹配
        'consumer_tag' => 'order'
    ],
    # fanout队列
    'fanout_queue' => [
        'exchange_name' => 'fanout_exchange',
        'exchange_type'=>'fanout',#扇形
        'queue_name' => 'fanout_queue',
        'route_key' => 'fanout_routerking',
        'consumer_tag' => 'fanout'
    ],
    # topic队列
    'topic_queue' => [
        'exchange_name' => 'topic_exchange',
        'exchange_type'=>'topic',#主题
        'queue_name' => 'topic_queue',
        'route_key' => "topic.order", //["topic.*","topic.#"]
        'consumer_tag' => 'topic'
    ]
];
